/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package petstore.model;

import javax.persistence.AttributeOverride;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * Entity class AnimalTransportado
 * 
 * @author Tom Hayden
 */
@Entity
@Table(name = "telefone")
@AttributeOverride(name="id", column=@Column(name="cdtelefone"))
public class Telefone extends BusinessObject {
    
    @Column(name = "ddd")
    private String DDD;
    
    @Column(name = "nrTelefone")
    private String numero;
    
    @ManyToOne
    @JoinColumn(name="cdtipotelefone")
    private TipoTelefone tipoTelefone;

    @Column(name = "ativo")
    private boolean active;
    
    /** Creates a new instance of Telefone */
    public Telefone() {
    }

    public String getDDD() {
        return DDD;
    }

    public void setDDD(String DDD) {
        this.DDD = DDD;
    }

    public String getNumero() {
        return numero;
    }

    public void setNumero(String numero) {
        this.numero = numero;
    }

    public TipoTelefone getTipoTelefone() {
        return tipoTelefone;
    }

    public void setTipoTelefone(TipoTelefone tipoTelefone) {
        this.tipoTelefone = tipoTelefone;
    }

    public boolean isActive() {
        return active;
    }

    public void setActive(boolean active) {
        this.active = active;
    }
    
}
